package com.muyu.kafka.service.impl;

import com.muyu.kafka.domain.Data1;
import com.muyu.kafka.domain.Data2;
import com.muyu.kafka.domain.Data3;
import com.muyu.kafka.mapper.KafkaMapper;
import com.muyu.kafka.service.KafkaService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.math.BigInteger;
import java.util.Date;
import java.util.List;

/**
 * @ClassName KafkaServiceImpl
 * @Description 描述
 * @Author ShiYu.Cui
 * @Date 2024/4/11 20:23
 */
@Service
public class KafkaServiceImpl implements KafkaService {
    @Autowired
    private KafkaMapper kafkaMapper;
    @Override
    public Integer findData1(BigInteger id) {
        Integer data1sList= kafkaMapper.findData1(id);
        return data1sList;
    }

    @Override
    public void insertData1(Data1 value) {
        kafkaMapper.insertData1(value);
    }

    @Override
    public void updateData1(Data1 value) {
        kafkaMapper.updateData1(value);
    }

    @Override
    public Integer findData2(BigInteger id) {
        Integer data2sList= kafkaMapper.findData2(id);
        return data2sList;
    }

    @Override
    public void insertData2(Data2 value2) {
        kafkaMapper.insertData2(value2);
    }
    @Override
    public void updateData2(Data2 value2) {
        kafkaMapper.updateData2(value2);
    }

    @Override
    public Integer findData3(BigInteger id) {
        Integer data3List= kafkaMapper.findData3(id);
        return data3List;
    }

    @Override
    public void insertData3(Data3 value) {
        kafkaMapper.insertData3(value);
    }

    @Override
    public void updateData3(Data3 value) {
        kafkaMapper.updateData3(value);
    }
    @Override
    public List<Data1> findData1All() {
        return kafkaMapper.findData1All();
    }

    @Override
    public Data2 finddata2(BigInteger id) {
        return kafkaMapper.finddata2(id);
    }

    @Override
    public Data3 finddata3(BigInteger id) {
        return kafkaMapper.finddata3(id);
    }

    @Override
    public void delete1ById(BigInteger id) {
        kafkaMapper.delete1ById(id);
    }

    @Override
    public void delete2ById(BigInteger id) {
        kafkaMapper.delete2ById(id);
    }

    @Override
    public void delete3ById(BigInteger id) {
        kafkaMapper.delete3ById(id);
    }

    @Override
    public List<Data1> findData1ByTime(Date time) {
        return kafkaMapper.findData1ByTime(time);
    }


}
